package com.info33.platform.system.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.info33.platform.business.app.vo.AppCenterVO;
import com.info33.platform.system.entity.SysUserProfile;
import com.info33.platform.system.vo.SysUserProfileVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/**
 * @author admin
 */
@Repository
public interface SysUserProfileDao extends BaseMapper<SysUserProfile> {

    /**
     * 根据用户 id，获取用户拓展信息
     *
     * @param uid-
     * @return -
     */
    SysUserProfileVO getByUserId(@Param("uid") Long uid);

    /**
     * app - 个人信息回显
     *
     * @param uid app 租户用户 id
     * @param tid 租户 id
     * @return vo
     */
    AppCenterVO appProfileEcho(@Param("uid") Long uid, @Param("tid") Long tid);

    /**
     * 根据租户用户 id，获取 db id
     *
     * @param id 租户用户 id
     * @return id
     */
    Long getIdByTenantUserId(
            @Param("id") Long id);

}